import seabot
from os import path
#from seasun.api import register_api

from config import Config

if __name__ == '__main__':
    seabot.init(Config)
    # register service api
    #register_api(seabot.get_web_server())
    # todo 获取配置事件流
    # 缓存重要信息，例如产品相关配置
    # 定制消息处理
    seabot.load_plugins(
        path.join(path.dirname(__file__), 'seasun', 'plugins'),
        'seasun.plugins'
    )

    seabot.run()
